#!/bin/bash
IOSIG_CFLAGS   += -g -w -finstrument-functions
IOSIG_LDFLAGS  += -L../../collect -liosig
IOSIG_LDFLAGS  += -Wl,-wrap,fopen,-wrap,fopen64,-wrap,fclose,-wrap,fread,-wrap,fwrite,-wrap,fseek,-wrap,open,-wrap,close,-wrap,read,-wrap,write,-wrap,lseek,-wrap,lseek64,-wrap,open64

CFLAGS      += ${IOSIG_CFLAGS}
LDFLAGS     += ${IOSIG_LDFLAGS}

simple_posix: simple_posix.o 
	gcc simple_posix.o -o simple_posix $(LDFLAGS)

simple_posix.o: simple_posix.c
	gcc $(CFLAGS) -c -o simple_posix.o simple_posix.c

clean:
	rm *.o simple_posix 

